const express=require('express')
let app=express()

let middleWare1=function(req,res,next){
req.money=100
console.log(111)
next()
console.log(111+'over')
}
let middleWare2=function(req,res,next){
    req.money+=20
    next()
    console.log(222+'over')
}
let middleWare3=function(req,res,next){
    req.money+=40
    next()
    console.log(333+'over')
}
app.use(middleWare1)
app.use(middleWare2)
app.use(middleWare3)

app.get("/",(req,res)=>{
    res.send("执行完毕"+req.money)
})
app.listen(8080)